
#include "jconcurrentinc.h"
#include <QString>
#include <QDebug>

extern std::string test1(int arg1, double arg2, const std::string &string)
{
    QString result =
            QString("arg1= %1, arg2= %2, string= %3").arg(arg1).arg(arg2).arg(string.c_str());

    return result.toStdString();
}

int main()
{
    int integer = 10;
    double floatingPoint = 10.23;
    std::string string = "hello,world";

    JFuture<std::string> future =
            JConcurrent::run(test1, integer, floatingPoint, string);

    future.waitForFinished();

    qDebug() << future.result().c_str();

    return 0;
}
